# -*- coding:utf-8 -*-

from com.mat.rpa.utils.globalConstants import GlobalConstants
from com.mat.rpa.views.workWindow.leftPanel.directiveTree import treeItem
from . import appOperationConstants

class AppOperationSubDirectiveTree(treeItem.TreeItemWithID):
    def __init__(self, parent):
        super(AppOperationSubDirectiveTree, self).__init__(parent)
        self.createAppOperationTreeNode()

    def createAppOperationTreeNode(self):
        self.nodeType = GlobalConstants.treeBranchType
        self.directiveType = "appOperation"
        self.setText(0,"应用操作")
        self.createTreeNode(GlobalConstants.treeLeafType,
                            self, appOperationConstants.AppOperationConstants.gettingAppParameterDirective, "获取应用程序参数")
        self.createTreeNode(GlobalConstants.treeLeafType,
                            self, appOperationConstants.AppOperationConstants.terminatingAppDirective, "终止应用")
        self.createTreeNode(GlobalConstants.treeLeafType,
                            self, appOperationConstants.AppOperationConstants.savingCustomDataDirective, "保存自定义数据")
        self.createTreeNode(GlobalConstants.treeLeafType,
                            self, appOperationConstants.AppOperationConstants.readingCustomDataDirective, "读取自定义数据")
        #挂载流程或应用操作子节点
